package com.example.eurekaclientconsumer;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * <p>
 * 此处的eureka-client-provider是eureka-client-provider模块的spring.application.name
 * </p>
 *
 * @author Zero
 * @since 2019/3/5
 */
@FeignClient(name = "eureka-client-provider", fallback = ExampleServiceFailure.class)
public interface ExampleService {

    @RequestMapping(value = "/hello", method = RequestMethod.GET)
    String hello(@RequestParam(value = "name") String name);

}
